Context-Free Recognition via Shortest Paths Computation: A Version of Valiant's Algorithm
نویسنده
چکیده
We present a new algorithm recognizing general context-free languages in O(BM(n)) time, where BM(n) is the time to multiply two n by n boolean matrices. The only known algorithm for this problem with the same asymptotic complexity is the Valiant's algorithm [Va75], which is quite sofisticated. The probem related to texts is reduced to arithmetics of matrices whose elements are in a semiring of a constant size. The main difficulty in Valiant’s algorthm is nonassociativity of considered semirings, the main point in our algorithm is that nonassociative semirings are replaced by associative ones. This simplifies the algorithm considerably. Our algorithm is more structured, its main part is a computation of shortest paths in a special graph called here the lattice graph. The Valiant's lemma, see [Ha78], is replaced here by a shortest paths lemma. The shortest paths problem for lattice graphs is also interested in its own.
منابع مشابه
All Pairs Shortest Paths Algorithms
Given a communication network or a road network one of the most natural algorithmic question is how to determine the shortest path from one point to another. In this paper we deal with one of the most fundamental problems of Graph Theory, the All Pairs Shortest Path (APSP) problem. We study three algorithms namely The FloydWarshall algorithm, APSP via Matrix Multiplication and the Johnson’s alg...
متن کاملShortest Anisotropic Paths on Terrains
We discuss the problem of computing shortest an-isotropic paths on terrains. Anisotropic path costs take into account the length of the path traveled, possibly weighted, and the direction of travel along the faces of the terrain. Considering faces to be weighted has added realism to the study of (pure) Euclidean shortest paths. Parameters such as the varied nature of the terrain, friction, or s...
متن کاملLabeled Shortest Paths
This paper gives a shortest path algorithm for CFG (context free grammar) labeled and weighted digraphs where edge weights may be positive or negative, but negative-weight cycles are not allowed in the underlying unlabled graph. These results build directly on an algorithm of Barrett, Jacob, and Marathe [1]. In addition to many other results, they gave a shortest path algorithm for CFG labeled ...
متن کاملRoute Planning for Bicycles - Exact Constrained Shortest Paths Made Practical via Contraction Hierarchy
We consider the problem of computing shortest paths subject to an additional resource constraint such as a hard limit on the (positive) height difference of the path. This is typically of interest in the context of bicycle route planning, or when energy consumption is to be limited. So far, the exact computation of such constrained shortest paths was not feasible on large networks; we show that...
متن کاملShortest (A+B)-path packing via hafnian
Björklund and Husfeldt developed a randomized polynomial time algorithm to solve the shortest two disjoint paths problem. Their algorithm is based on computation of permanents modulo 4 and the isolation lemma. In this paper, we consider the following generalization of the shortest two disjoint paths problem, and develop a similar algebraic algorithm. The shortest perfect (A + B)-path packing pr...
متن کاملذخیره در منابع من
با ذخیره ی این منبع در منابع من، دسترسی به آن را برای استفاده های بعدی آسان تر کنید
عنوان ژورنال:
- Theor. Comput. Sci.
دوره 143 شماره
صفحات -
تاریخ انتشار 1995